<?php
/*
 * Copyright (c) 2017-2025 Tencent. All Rights Reserved.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *    http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
namespace TencentCloud\Waf\V20180125\Models;
use TencentCloud\Common\AbstractModel;

/**
 * SearchAttackLog response structure.
 *
 * @method integer getCount() Obtain Number of attack logs returned
 * @method void setCount(integer $Count) Set Number of attack logs returned
 * @method string getContext() Obtain API upgrade: this field is invalid, defaults to returning an empty string
 * @method void setContext(string $Context) Set API upgrade: this field is invalid, defaults to returning an empty string
 * @method array getData() Obtain Attack log array entry content
 * @method void setData(array $Data) Set Attack log array entry content
 * @method boolean getListOver() Obtain CLS API returned content
 * @method void setListOver(boolean $ListOver) Set CLS API returned content
 * @method boolean getSqlFlag() Obtain CLS API returned content, indicating whether to enable the new version index
 * @method void setSqlFlag(boolean $SqlFlag) Set CLS API returned content, indicating whether to enable the new version index
 * @method string getRequestId() Obtain The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem.
 * @method void setRequestId(string $RequestId) Set The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem.
 */
class SearchAttackLogResponse extends AbstractModel
{
    /**
     * @var integer Number of attack logs returned
     */
    public $Count;

    /**
     * @var string API upgrade: this field is invalid, defaults to returning an empty string
     */
    public $Context;

    /**
     * @var array Attack log array entry content
     */
    public $Data;

    /**
     * @var boolean CLS API returned content
     */
    public $ListOver;

    /**
     * @var boolean CLS API returned content, indicating whether to enable the new version index
     */
    public $SqlFlag;

    /**
     * @var string The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem.
     */
    public $RequestId;

    /**
     * @param integer $Count Number of attack logs returned
     * @param string $Context API upgrade: this field is invalid, defaults to returning an empty string
     * @param array $Data Attack log array entry content
     * @param boolean $ListOver CLS API returned content
     * @param boolean $SqlFlag CLS API returned content, indicating whether to enable the new version index
     * @param string $RequestId The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem.
     */
    function __construct()
    {

    }

    /**
     * For internal only. DO NOT USE IT.
     */
    public function deserialize($param)
    {
        if ($param === null) {
            return;
        }
        if (array_key_exists("Count",$param) and $param["Count"] !== null) {
            $this->Count = $param["Count"];
        }

        if (array_key_exists("Context",$param) and $param["Context"] !== null) {
            $this->Context = $param["Context"];
        }

        if (array_key_exists("Data",$param) and $param["Data"] !== null) {
            $this->Data = [];
            foreach ($param["Data"] as $key => $value){
                $obj = new AttackLogInfo();
                $obj->deserialize($value);
                array_push($this->Data, $obj);
            }
        }

        if (array_key_exists("ListOver",$param) and $param["ListOver"] !== null) {
            $this->ListOver = $param["ListOver"];
        }

        if (array_key_exists("SqlFlag",$param) and $param["SqlFlag"] !== null) {
            $this->SqlFlag = $param["SqlFlag"];
        }

        if (array_key_exists("RequestId",$param) and $param["RequestId"] !== null) {
            $this->RequestId = $param["RequestId"];
        }
    }
}
